
$(document).ready(function(){
	//var s =new Date();
	nowDate = (new Date()).toLocaleString().substring(0, 10);
	//$.formValidator.initConfig({onError:function(){alert("校验没有通过，具体错误请看错误提示")}});
	$.formValidator.initConfig({formID:"addStaff",inIframe:true,mode:'AlertTip',onError:function(msg){alert(msg)}});
	$("#addStaff_staff_name").formValidator({trim:true}).inputValidator({min:1,onError:"姓名不能为空!"});
	$("#addStaff_staff_identityNo").formValidator({trim:true}).functionValidator({fun:isCardID});
	$("#addStaff_staff_birthday").formValidator({empty:false}).inputValidator({min:"1900-01-01",max:nowDate,type:"value",onError:"日期必须在\"1900-01-01\"和"+nowDate+"之间"});
	$("#addStaff_staff_phone").formValidator({trim:true,empty:false}).inputValidator({min:11,max:11,onError:"手机号码必须是11位的,请确认"}).regexValidator({regExp:"mobile",dataType:"enum",onError:"你输入的手机号码格式不正确"});;
	$("#lxdh").formValidator({empty:true}).regexValidator({regExp:"^[[0-9]{3}-|\[0-9]{4}-]?([0-9]{8}|[0-9]{7})?$",onError:"你输入的联系电话格式不正确"});

}); 
